<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>微服务架构核心组件全景图</title>
    <link href="https://cdn.staticfile.org/font-awesome/6.4.0/css/all.min.css" rel="stylesheet">
    <link href="https://cdn.staticfile.org/tailwindcss/2.2.19/tailwind.min.css" rel="stylesheet">
    <link href="https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@400;500;600;700&family=Noto+Sans+SC:wght@300;400;500;700&display=swap" rel="stylesheet">
    <script src="https://cdn.jsdelivr.net/npm/mermaid@latest/dist/mermaid.min.js"></script>
    <style>
        body {
            font-family: 'Noto Sans SC', Tahoma, Arial, Roboto, "Droid Sans", "Helvetica Neue", "Droid Sans Fallback", "Heiti SC", "Hiragino Sans GB", Simsun, sans-serif;
            background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
            min-height: 100vh;
        }
        
        /* Hero 区域样式 */
        .hero-gradient {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            position: relative;
            overflow: hidden;
        }
        
        .hero-pattern {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
        }
        
        /* 首字下沉效果 */
        .drop-cap::first-letter {
            float: left;
            font-size: 4rem;
            line-height: 3rem;
            padding-right: 0.5rem;
            margin-top: 0.25rem;
            font-weight: 700;
            color: #667eea;
        }
        
        /* 卡片悬停效果 */
        .card-hover {
            transition: all 0.3s ease;
            cursor: pointer;
        }
        
        .card-hover:hover {
            transform: translateY(-5px);
            box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
        }
        
        /* 渐变文字效果 */
        .gradient-text {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }
        
        /* 分割线样式 */
        .section-divider {
            position: relative;
            text-align: center;
            margin: 4rem 0;
        }
        
        .section-divider::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 0;
            right: 0;
            height: 1px;
            background: linear-gradient(to right, transparent, #e0e0e0, transparent);
        }
        
        .section-divider span {
            background: #f5f7fa;
            padding: 0 2rem;
            position: relative;
            font-size: 0.875rem;
            color: #9ca3af;
        }
        
        /* 数字标记样式 */
        .number-badge {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 2rem;
            height: 2rem;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            border-radius: 50%;
            font-weight: 700;
            margin-right: 0.75rem;
        }
        
        /* 引用样式 */
        .quote-box {
            position: relative;
            padding: 2rem 3rem;
            background: white;
            border-left: 4px solid #667eea;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
        }
        
        .quote-box::before {
            content: '"';
            position: absolute;
            top: -10px;
            left: 20px;
            font-size: 4rem;
            color: #667eea;
            opacity: 0.2;
        }
        
        /* 滚动动画 */
        .fade-in {
            opacity: 0;
            transform: translateY(20px);
            transition: all 0.6s ease;
        }
        
        .fade-in.visible {
            opacity: 1;
            transform: translateY(0);
        }
        
        /* Mermaid 图表样式 */
        .mermaid {
            display: flex;
            justify-content: center;
            margin: 2rem 0;
        }
    </style>
</head>
<body>
    <!-- Hero 区域 -->
    <section class="hero-gradient text-white py-20 relative">
        <div class="hero-pattern"></div>
        <div class="container mx-auto px-6 relative z-10">
            <div class="text-center">
                <h1 class="text-5xl md:text-6xl font-bold mb-6 tracking-tight">
                    微服务架构核心组件
                    <span class="block text-3xl md:text-4xl mt-4 font-light opacity-90">构建现代分布式系统的基石</span>
                </h1>
                <p class="text-xl md:text-2xl max-w-4xl mx-auto leading-relaxed opacity-95">
                    深入探索微服务架构中的九大核心组件，从服务注册发现到分布式追踪，
                    全面解析如何构建高可用、可扩展的分布式系统
                </p>
                <div class="mt-10 flex justify-center space-x-6">
                    <div class="text-center">
                        <div class="text-4xl font-bold">9</div>
                        <div class="text-sm opacity-75">核心组件</div>
                    </div>
                    <div class="text-center border-l border-white border-opacity-30 pl-6">
                        <div class="text-4xl font-bold">100%</div>
                        <div class="text-sm opacity-75">实战覆盖</div>
                    </div>
                    <div class="text-center border-l border-white border-opacity-30 pl-6">
                        <div class="text-4xl font-bold">2024</div>
                        <div class="text-sm opacity-75">最新实践</div>
                    </div>
                </div>
            </div>
        </div>
    </section>

    <!-- 引言部分 -->
    <section class="py-16 bg-white">
        <div class="container mx-auto px-6 max-w-4xl">
            <div class="quote-box rounded-lg fade-in">
                <p class="text-lg leading-relaxed text-gray-700 drop-cap">
                    微服务架构已经成为当今软件开发中的主流范式，它不仅仅是一种技术选型，更是一种设计理念和架构风格的演进。随着云计算和分布式系统的快速发展，微服务以其灵活性、可扩展性和快速部署的优势，逐渐取代了传统的单体应用架构，成为企业构建大规模、复杂业务系统的首选方式。
                </p>
            </div>
            
            <div class="mt-12 grid md:grid-cols-3 gap-6 fade-in">
                <div class="text-center p-6 bg-gray-50 rounded-lg">
                    <i class="fas fa-rocket text-4xl text-purple-600 mb-4"></i>
                    <h3 class="font-bold text-lg mb-2">快速部署</h3>
                    <p class="text-gray-600 text-sm">独立部署，持续交付</p>
                </div>
                <div class="text-center p-6 bg-gray-50 rounded-lg">
                    <i class="fas fa-expand-arrows-alt text-4xl text-purple-600 mb-4"></i>
                    <h3 class="font-bold text-lg mb-2">弹性扩展</h3>
                    <p class="text-gray-600 text-sm">按需扩容，资源优化</p>
                </div>
                <div class="text-center p-6 bg-gray-50 rounded-lg">
                    <i class="fas fa-shield-alt text-4xl text-purple-600 mb-4"></i>
                    <h3 class="font-bold text-lg mb-2">故障隔离</h3>
                    <p class="text-gray-600 text-sm">服务自治，影响可控</p>
                </div>
            </div>
        </div>
    </section>

    <!-- 架构全景图 -->
    <section class="py-16 bg-gray-50">
        <div class="container mx-auto px-6">
            <h2 class="text-3xl font-bold text-center mb-12 gradient-text">微服务架构全景图</h2>
            <div class="bg-white rounded-xl shadow-lg p-8 fade-in">
                <div class="mermaid">
                    graph TB
                        subgraph "客户端层"
                            A[Web应用]
                            B[移动应用]
                            C[第三方系统]
                        end
                        
                        subgraph "网关层"
                            D[API网关<br/>路由/认证/限流]
                        end
                        
                        subgraph "服务层"
                            E[用户服务]
                            F[订单服务]
                            G[支付服务]
                            H[库存服务]
                        end
                        
                        subgraph "基础设施层"
                            I[服务注册中心]
                            J[配置中心]
                            K[消息队列]
                            L[分布式追踪]
                        end
                        
                        A --> D
                        B --> D
                        C --> D
                        D --> E
                        D --> F
                        D --> G
                        D --> H
                        E -.-> I
                        F -.-> I
                        G -.-> I
                        H -.-> I
                        E -.-> J
                        F -.-> J
                        G -.-> K
                        H -.-> K
                        E -.-> L
                        F -.-> L
                        
                        style D fill:#667eea,stroke:#fff,color:#fff
                        style I fill:#f59e0b,stroke:#fff,color:#fff
                        style J fill:#10b981,stroke:#fff,color:#fff
                        style K fill:#ef4444,stroke:#fff,color:#fff
                        style L fill:#3b82f6,stroke:#fff,color:#fff
                </div>
            </div>
        </div>
    </section>

    <!-- 核心组件详解 -->
    <section class="py-16 bg-white">
        <div class="container mx-auto px-6">
            <h2 class="text-4xl font-bold text-center mb-16">核心组件深度解析</h2>
            
            <!-- 服务注册与发现 -->
            <div class="max-w-6xl mx-auto mb-20 fade-in">
                <div class="flex items-center mb-8">
                    <span class="number-badge">1</span>
                    <h3 class="text-3xl font-bold gradient-text">服务注册与发现</h3>
                </div>
                
                <div class="grid md:grid-cols-2 gap-8">
                    <div class="bg-gradient-to-br from-purple-50 to-pink-50 p-8 rounded-xl">
                        <h4 class="text-xl font-bold mb-4 text-purple-800">
                            <i class="fas fa-network-wired mr-2"></i>核心功能
                        </h4>
                        <ul class="space-y-3">
                            <li class="flex items-start">
                                <i class="fas fa-check-circle text-purple-600 mt-1 mr-3"></i>
                                <span class="text-gray-700">服务自动注册：微服务启动时自动向注册中心注册自身信息</span>
                            </li>
                            <li class="flex items-start">
                                <i class="fas fa-check-circle text-purple-600 mt-1 mr-3"></i>
                                <span class="text-gray-700">动态服务发现：实时获取可用服务实例列表</span>
                            </li>
                            <li class="flex items-start">
                                <i class="fas fa-check-circle text-purple-600 mt-1 mr-3"></i>
                                <span class="text-gray-700">健康检查机制：定期心跳检测，自动剔除故障节点</span>
                            </li>
                        </ul>
                    </div>
                    
                    <div class="bg-white border border-gray-200 p-8 rounded-xl card-hover">
                        <h4 class="text-xl font-bold mb-4 text-gray-800">
                            <i class="fas fa-tools mr-2"></i>主流实现
                        </h4>
                        <div class="grid grid-cols-2 gap-4">
                            <div class="text-center p-4 bg-gray-50 rounded-lg">
                                <i class="fab fa-java text-3xl text-orange-500 mb-2"></i>
                                <div class="font-semibold">Eureka</div>
                                <div class="text-sm text-gray-600">Netflix开源</div>
                            </div>
                            <div